
<include file="App/Admin/View/Public/left.html"/>
<div class="admin">

<div class="panel admin-panel">
  <div class="panel-head"><strong><span class="icon-pencil-square-o"></span> 网站信息</strong></div>
  <div class="body-content">
    <form method="post" class="form-x" action="{:U('Config/updateCofig')}" enctype="multipart/form-data">
    <notempty>
      <div class="form-group">
      <div class="label">
        <label>首页LOGO：</label>
      </div>
      <div class="field" id="preview">
        <img style="width: 200px;" src="{$config.logo}">
      </div>
      </div> 
    </notempty> 
    <div class="form-group">
        <div class="label">
          <label></label>
        </div>
        <div class="field">    
      <a class="button input-file bg-blue margin-left" href="javascript:void(0);">+ 首页LOGO<input size="100" type="file" name="logo"   onchange="preview(this)"/></a>
        </div>
     </div>
    
    
      
 
    <div class="form-group">
        <div class="label">
          <label>公司名称：</label>
        </div>
        <div class="field">
    <input type="text" class="input"  value="{$config.name}" name="name" />
        </div>
      </div>
	  <div class="form-group">
        <div class="label">
          <label>网站关键字：</label>
        </div>
        <div class="field">
    <input type="text" class="input"  value="{$config.keywords}" name="keywords" />
        </div>
      </div>
      <div class="form-group">
        <div class="label">
          <label>网站描述：</label>
        </div>
        <div class="field">
    <textarea name="desc" style='width:300px;height:150px'>{$config.desc}</textarea>
        </div>
      </div>
    <div class="form-group">
        <div class="label">
          <label>版权信息：</label>
        </div>
        <div class="field">
      <input type="text" class="input" name="copyright" value="{$config.copyright}"  />
        </div>
      </div>
    <!-- <div class="form-group"> -->
        <!-- <div class="label"> -->
          <!-- <label>备案信息：</label> -->
        <!-- </div> -->
        <!-- <div class="field"> -->
      <!-- <input type="text" class="input" name="record" value="{$config.record}"  /> -->
        <!-- </div> -->
      <!-- </div> -->
      <div class="form-group" >
        <div class="label">
          <label>公司电话：</label>
        </div>
        <div class="field">
          <input type="text" class="input" name="phone" value="{$config.phone}" />
          <div class="tips"></div>
        </div>
      </div>
	  <div class="form-group" >
        <div class="label">
          <label>传真：</label>
        </div>
        <div class="field">
          <input type="text" class="input" name="fax" value="{$config.fax}" />
          <div class="tips"></div>
        </div>
      </div>
      <div class="form-group">
        <div class="label">
          <label>地址：</label>
        </div>
        <div class="field">
          <input type="text" class="input" name="address" value="{$config.address}" />
          <div class="tips"></div>
        </div>
      </div>  
      <div class="form-group">
        <div class="label">
          <label></label>
        </div>
        <div class="field">
          <button class="button bg-main icon-check-square-o" type="submit"> 提交</button>
        </div>
      </div>
    </form>
  </div>
</div></div>
</body></html>
<script type="text/javascript">    
 function preview(file)  
 {  
 var prevDiv = document.getElementById('preview');  
 if (file.files && file.files[0])  
 {  
 var reader = new FileReader();  
 reader.onload = function(evt){  
 prevDiv.innerHTML = '<img src="' + evt.target.result + '" />';  
}    
 reader.readAsDataURL(file.files[0]);  
}   
}
function preview2(file)  
 {  
 var prevDiv = document.getElementById('preview2');  
 if (file.files && file.files[0])  
 {  
 var reader = new FileReader();  
 reader.onload = function(evt){  
 prevDiv.innerHTML = '<img src="' + evt.target.result + '" />';  
}    
 reader.readAsDataURL(file.files[0]);  
}   
}
function preview3(file)  
 {  
 var prevDiv = document.getElementById('preview3');  
 if (file.files && file.files[0])  
 {  
 var reader = new FileReader();  
 reader.onload = function(evt){  
 prevDiv.innerHTML = '<img src="' + evt.target.result + '" />';  
}    
 reader.readAsDataURL(file.files[0]);  
}   
}
function preview4(file)  
 {  
 var prevDiv = document.getElementById('preview4');  
 if (file.files && file.files[0])  
 {  
 var reader = new FileReader();  
 reader.onload = function(evt){  
 prevDiv.innerHTML = '<img src="' + evt.target.result + '" />';  
}    
 reader.readAsDataURL(file.files[0]);  
}   
}
function preview5(file)  
 {  
 var prevDiv = document.getElementById('preview5');  
 if (file.files && file.files[0])  
 {  
 var reader = new FileReader();  
 reader.onload = function(evt){  
 prevDiv.innerHTML = '<img src="' + evt.target.result + '" />';  
}    
 reader.readAsDataURL(file.files[0]);  
}   
}
 </script>